class MyParentClass {

    this.MyParentClass = function () {
        this.d = 0;
    };

    this.test = function () {
        this.d++;
    };
}